package cn.edu.xhu.library_management.book.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 借阅表
 * @TableName lm_borrow
 */
@TableName(value ="lm_borrow")
@Data
public class LmBorrow implements Serializable {
    /**
     * 借阅Id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 用户Id
     */
    @TableField(value = "user_account")
    private String userAccount;

    /**
     * 用户类型 1 学生 2 教师 3 校外用户
     */
    @TableField(value = "user_type")
    private Integer userType;

    /**
     * 图书id
     */
    @TableField(value = "book_id")
    private Integer bookId;

    /**
     * 删除标识(0 删除  1 未删除)
     */
    @TableField(value = "bo_del_flag")
    @TableLogic
    private String boDelFlag;

    /**
     * 借阅状态(0 已归还   1 未归还)
     */
    @TableField(value = "bo_status")
    private String boStatus;

    /**
     * 创建时间
     */
    @TableField(value = "bo_creat_time",fill = FieldFill.INSERT)
    private Date creatTime;

    /**
     * 归还时间
     */
    @TableField(value = "bo_return_time")
    private Date boReturnTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}